<?php

class Router {
	
	public $page;
	public $lang;
	public $id;
	
	public function __construct() {
		$this->page = (isset($_GET['page']) ? $_GET['page'] : "home");
		$this->lang = (isset($_GET['lang']) ? $_GET['lang'] : "en");
		$this->id = (isset($_GET['id']) ? $_GET['id'] : ($this->page == "game" ? "a4" : false));
		
		$this->page = (file_exists("pages/" . $this->page . ".php") ? $this->page : "about");
	}
	
	public function RenderPage() {
		include ("pages/" . $this->page . ".php");
	}

	
}

?>